<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1">
    <meta content="telephone=no" name="format-detection"/>
    <script>
        var isJsBridgeReady = false;
        var isZHKIOS= false;
        function readyFunc(device){
            isJsBridgeReady = true;
            if(device == 'true'){
              isZHKIOS = true;
            }
        }
    </script>
    <title>门店管理</title>

    <!-- css -->
    <link rel="stylesheet" href="../css/pro_app.min.css"/>
    <link rel="stylesheet" href="../lib/yz-sm.min.css"/>
    <link rel="stylesheet" href="../lib/swiper.min.css"/>
    <link rel="stylesheet" href="../lib/mobiscroll/mobiscroll.custom-2.17.0.min.css"/>

</head>

<body>
    <div class="page-group">
        <div class="page store-manage" id="storeManagePage">
                <div class="scroll-view">
                 <ul class="header">
                    <li class="left"><a class="external back" href="javascript:void(0);" name="back"><i class="zhk-list_larrow"></i>返回</a></li>
                    <li class="middle">门店管理</li>
                    <li class="right"></li>
                </ul>
                <div class="page-body">
                    <div id="storeManageContainer"></div>
                </div>
            </div>
            <!-- 模版 -->
            <script type="text/template" id="storeManageTPL">
                <ul class="list">
                    {{each data as element index}}
                    <li shopId="{{element.shopId}}" channel="{{element.payChannel}}">
                        {{if element.serviceVersionType == constants.store.SERVICE_VERSION_TYPE.none}}
                        <span class="icon not-open">{{constants.store.getServiceVersionTypeText(element.serviceVersionType)}}</span>
                        {{else if element.serviceVersionType == constants.store.SERVICE_VERSION_TYPE.gold}}
                        <span class="icon orange-gradient">{{constants.store.getServiceVersionTypeText(element.serviceVersionType)}}</span>
                        {{else if element.serviceVersionType == constants.store.SERVICE_VERSION_TYPE.silver}}
                        <span class="icon green-gradient">{{constants.store.getServiceVersionTypeText(element.serviceVersionType)}}</span>
                        {{else if element.serviceVersionType == constants.store.SERVICE_VERSION_TYPE.cloud_share_pay}}
                        <span class="icon blue-gradient">{{constants.store.getServiceVersionTypeText(element.serviceVersionType)}}</span>
                        {{else}}
                        <span class="icon"></span>
                        {{/if}}

                        <span class="info">
                            <p class="name">{{element.mainShopName}}{{element.branchShopName?"("+element.branchShopName+")" : ""}}</p>
                            <p class="state">
                                <span>门店状态：{{constants.store.getKoubeiStatus(element.isOnline)}}</span>
                                <span>订购状态：
                                {{if element.serviceVersionType == constants.store.SERVICE_VERSION_TYPE.none}}
                                    未订购
                                {{else if element.serviceVersionType == constants.store.SERVICE_VERSION_TYPE.cloud_share_pay}}
                                    {{constants.store.getCloudSharePayStatusText(element.aPayCodeStatus)}}
                                {{else}}
                                    {{constants.store.getSubscribeStatus(element.proUpgradeStatus)}}
                                {{/if}}
                                </span>
                            </p>
                        </span>

                        <span class="skip">
                            <i class="zhk-list_rarrow"></i>
                        </span>
                    </li>
                    {{/each}}
                </ul>
            </script>
            <script type="text/template" id="storeManage4NoDataTPL">
                <div class="no-data-wrap">
                    <div class="no-data"></div>
                    <p>暂时没有门店</p>
                </div>
            </script>

        </div>
    </div>

    <!-- js -->
    <script src="../lib/zepto.min.js" charset="utf-8"></script>
    <script src="../lib/yz-sm.min.js" charset="utf-8"></script>
    <script src="../lib/template.js" charset="utf-8"></script>
    <script src="../lib/swiper.min.js" charset="utf-8"></script>
    <script src="../lib/mobiscroll/mobiscroll.custom-2.17.0.min.js" charset="utf-8"></script>

    <script src="../base/base.js" charset="utf-8"></script>
    <script src="../js/main.js" charset="utf-8"></script>

</body>
</html>
